//////////////////////////////////////////////////////////////////////////
#pragma once


//////////////////////////////////////////////////////////////////////////
#include <RocketLua/RocketLua.hpp>


namespace Rocket
{
	namespace Core
	{
		namespace Lua
		{
			//////////////////////////////////////////////////////////////////////////
			class ROCKETLUA_EXPORT Vector2f
			{
			public:
				Vector2f();
				Vector2f( float x, float y );

				float				X() const;
				void				X( float x );
				float				Y() const;
				void				Y( float y );

				Vector2f&			Set( float x, float y );

				bool				operator == ( const Vector2f& rhs ) const;

				Vector2f			Negate() const;

				Vector2f			operator +( const Vector2f& rhs ) const;
				Vector2f			operator -( const Vector2f& rhs ) const;
				Vector2f			operator *( float rhs ) const;
				Vector2f			operator /( float rhs ) const;

				float				Magnitude() const;

				static void			Register( lua_State* );

			private:
				float				mX;
				float				mY;
			};
		}
	}
}
